/*
 *代码由框架生成,任何更改都可能导致被代码生成器覆盖
 *如果数据库字段发生变化，请在代码生器重新生成此Model
 */
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using SqlSugar;
using DGZImp.SysEntity;

namespace DGZImp.BasProject.DomainModels
{
    [Entity(TableCnName = "工单信息",TableName = "Aps_Mo",DBServer = "ServiceDbContext")]
    public partial class Aps_Mo:ServiceEntity
    {
        /// <summary>
       ///订单
       /// </summary>
       [Display(Name ="订单")]
       [Column(TypeName="bigint")]
       [Editable(true)]
       public long? SalesOrderId { get; set; }

       /// <summary>
       ///ID
       /// </summary>
       [SugarColumn(IsPrimaryKey = true)]
       [Key]
       [Display(Name ="ID")]
       [Column(TypeName="bigint")]
       [Required(AllowEmptyStrings=false)]
       public long MoId { get; set; }

       /// <summary>
       ///前序工单
       /// </summary>
       [Display(Name ="前序工单")]
       [Column(TypeName="bigint")]
       public long? ParentId { get; set; }

       /// <summary>
       ///工单号
       /// </summary>
       [Display(Name ="工单号")]
       [MaxLength(50)]
       [Column(TypeName="nvarchar(50)")]
       [Editable(true)]
       public string MoCode { get; set; }

       /// <summary>
       ///工单种类
       /// </summary>
       [Display(Name ="工单种类")]
       [Column(TypeName="int")]
       [Editable(true)]
       public int? MoType { get; set; }

       /// <summary>
       ///投料批号
       /// </summary>
       [Display(Name ="投料批号")]
       [MaxLength(100)]
       [Column(TypeName="nvarchar(100)")]
       [Editable(true)]
       public string LotNo { get; set; }

       /// <summary>
       ///数量
       /// </summary>
       [Display(Name ="数量")]
       [DisplayFormat(DataFormatString="20,4")]
       [Column(TypeName="decimal")]
       [Editable(true)]
       public decimal? Qty { get; set; }

       /// <summary>
       ///重量
       /// </summary>
       [Display(Name ="重量")]
       [DisplayFormat(DataFormatString="20,4")]
       [Column(TypeName="decimal")]
       public decimal? Weight { get; set; }

       /// <summary>
       ///产品
       /// </summary>
       [Display(Name ="产品")]
       [MaxLength(120)]
       [Column(TypeName="nvarchar(120)")]
       [Editable(true)]
       public string ProductsCode { get; set; }

       /// <summary>
       ///状态
       /// </summary>
       [Display(Name ="状态")]
       [Column(TypeName="int")]
       [Editable(true)]
       public int? Status { get; set; }

       /// <summary>
       ///是否已排程
       /// </summary>
       [Display(Name ="是否已排程")]
       [Column(TypeName="int")]
       public int? IsSchedule { get; set; }

       /// <summary>
       ///出货日
       /// </summary>
       [Display(Name ="出货日")]
       [Column(TypeName="datetime")]
       [Editable(true)]
       public DateTime? DeadLine { get; set; }

       /// <summary>
       ///完成数量
       /// </summary>
       [Display(Name ="完成数量")]
       [DisplayFormat(DataFormatString="20,4")]
       [Column(TypeName="decimal")]
       public decimal? FinishedQty { get; set; }

       /// <summary>
       ///完成重量
       /// </summary>
       [Display(Name ="完成重量")]
       [DisplayFormat(DataFormatString="20,4")]
       [Column(TypeName="decimal")]
       public decimal? FinishedWeight { get; set; }

       /// <summary>
       ///是否有效
       /// </summary>
       [Display(Name ="是否有效")]
       [Column(TypeName="int")]
       public int? IsValid { get; set; }

       /// <summary>
       ///创建用户
       /// </summary>
       [Display(Name ="创建用户")]
       [Column(TypeName="bigint")]
       public long? CreateId { get; set; }

       /// <summary>
       ///创建人
       /// </summary>
       [Display(Name ="创建人")]
       [MaxLength(50)]
       [Column(TypeName="nvarchar(50)")]
       public string Creator { get; set; }

       /// <summary>
       ///创建时间
       /// </summary>
       [Display(Name ="创建时间")]
       [Column(TypeName="datetime")]
       public DateTime? CreateTime { get; set; }

       /// <summary>
       ///修改用户
       /// </summary>
       [Display(Name ="修改用户")]
       [Column(TypeName="bigint")]
       public long? ModifyId { get; set; }

       /// <summary>
       ///修改人
       /// </summary>
       [Display(Name ="修改人")]
       [MaxLength(30)]
       [Column(TypeName="nvarchar(30)")]
       public string Modifier { get; set; }

       /// <summary>
       ///修改时间
       /// </summary>
       [Display(Name ="修改时间")]
       [Column(TypeName="datetime")]
       public DateTime? ModifyTime { get; set; }

       /// <summary>
       ///备注
       /// </summary>
       [Display(Name ="备注")]
       [MaxLength(512)]
       [Column(TypeName="nvarchar(512)")]
       [Editable(true)]
       public string Remarks { get; set; }

       /// <summary>
       ///产品
       /// </summary>
       [Display(Name ="产品")]
       [Column(TypeName="bigint")]
       public long? MaterialId { get; set; }

       /// <summary>
       ///层级，越小表示越靠近成品
       /// </summary>
       [Display(Name ="层级，越小表示越靠近成品")]
       [Column(TypeName="int")]
       public int? Level { get; set; }

       
    }
}